package com.unitd.base.frame.plugin.db.datasource.context;

import org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource;

/**
 * @author hudan
 * @version 1.0
 * @filename DynamicDataSource.java
 * @copyright www.unitd.com
 * @date 2020-07-08
 */

public class DynamicDataSource extends AbstractRoutingDataSource {
    public DynamicDataSource() {
    }

    @Override
    protected Object determineCurrentLookupKey() {
        return DataSourceContextHolder.getDataSourceType();
    }
}